<div id="loginbox" class="corner-top">
{if $user.session_logged_in eq 0}
<div class="p-t-5 p-b-5">
<a class="sprite-cross close-loginbox" title="{$lang.login}" href="#"></a>&nbsp;&nbsp;&nbsp;
<a href="#" class="ts-011 trigger-loginbox" data-target="loginarea" data-parent="remind"><span class="sprite-icons sprite-key"></span>&nbsp;GİRİŞ</a>&nbsp;&nbsp;&nbsp;
<a href="{$config.docroot}login/{$req.default_index}" class="ts-011" data-target=""><span class="sprite-icons sprite-pencil"></span>&nbsp;KAYIT OL</a>
</div>

<div id="loginarea" class="loginbox hide bt-solid bc-fff">
<form class="forms-login" onsubmit="return false;" id="form-login">
<input type="text" name="username" class="loginarea-input" data-default_text="{$lang.p_login.username}" /><br />
<input type="password" name="password" class="vmiddle loginarea-input" data-default_text="{$lang.p_login.password}" /><br />
<a class="button3d green submit" href="#" title="{$lang.login}" data-formid="form-login" data-action="login">{$lang.login}</a>
<div class="clear m-b-5" style="height:1px;"></div>
<a href="#" class="fs-10 trigger-loginbox"  data-target="remind" data-parent="loginarea"><span class="sprite-icons sprite-help"></span>{$lang.p_login.forgotpass}</a>
</form>
</div>


<div id="remind" class="loginbox hide bt-solid bc-fff">
<form class="forms-login" onsubmit="return false;" id="form-remind">
<input type="text" name="user_email" class="loginarea-input" data-default_text="{$lang.p_login.user_email}" /><br />
<a class="button3d green submit" href="#" title="{$lang.login}" data-formid="form-remind" data-action="remind">{$lang.submit}</a>
</form>

</div>

{capture "js_loginbox"}
{literal}
<script type="text/javascript">
$(function(){
$('#loginbox .trigger-loginbox').click(function(){
var _targ = $(this).data('target');
var _parent = $(this).data('parent');
	$('#loginbox #'+_parent).slideUp(function(){
		$('#loginbox #'+_targ).slideDown();
		$('#loginbox .close-loginbox').addClass('sprite-icons');
	});
return false;
});
$('#loginbox .close-loginbox').click(function(){
		$('#loginbox .loginbox').slideUp();
		$(this).removeClass('sprite-icons');
		return false;
});

	$('#loginbox .loginbox input').each(function(i,v){
		var _this = $(this);
		var _default_text = $(this).data('default_text');
		_this.val(_default_text);
		_this.blur(function(){
			if(_this.val() == '')
			{
				_this.val(_default_text);
			}
		});
		_this.focus(function(){
			if(_this.val() == _default_text)
			{
				_this.val('');
			}
		});
	});
});
</script>
{/literal}
{/capture}
{else}
<div id="logoutarea" class="loginbox relative">
<div style="padding-left:60px;padding-top:5px; color:#fff">
<a href="#" class="loginarea-userinfo submit" data-action="userinfo" title="{$lang.p_login.account_info}"><span class="sprite-icons sprite-user"></span></a> {$user.user_firstname} {$user.user_surname} 
<a class="loginarea-submit submit" href="{$config.docroot}login/{$req.default_index}?logout=true" title="{$lang.logout}" data-action="logout">&nbsp;</a>
</div>
</div>
{/if}
</div>